//
//  ProductSKUView.h
//  BaseProject
//
//  Created by 王洋 on 2020/8/4.
//  Copyright © 2020 王洋. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "CommonSkuModel.h"

NS_ASSUME_NONNULL_BEGIN

typedef NS_ENUM(NSInteger, ProductSKUViewActionType) {
    ProductSKUViewActionType_none,
    //购物车
    ProductSKUViewActionType_cart,
    //购买
    ProductSKUViewActionType_buy
};

@interface ProductSKUView : UIView

@property (weak, nonatomic) IBOutlet UIImageView *skuImageView;

@property (weak, nonatomic) IBOutlet UILabel *skuPriceLab;

@property (weak, nonatomic) IBOutlet UILabel *skuStockLab;

@property (weak, nonatomic) IBOutlet UILabel *selSKULab;

@property (weak, nonatomic) IBOutlet UITextField *countTF;

@property (weak, nonatomic) IBOutlet UIButton *handleBtn;

@property (weak, nonatomic) IBOutlet UICollectionView *collectionview;

@property (nonatomic, assign) ProductSKUViewActionType type;

@property (nonatomic, strong) CommonSkuModel *selectModel;

@property (nonatomic, strong) NSMutableArray <CommonSkuModel *>* dataArray;

- (void)fillSkuViewWithArray:(NSMutableArray <CommonSkuModel *>*)dataArray Type:(ProductSKUViewActionType)type;

@property (nonatomic, copy) void(^ProductSKUViewBlock)(CommonSkuModel *model, ProductSKUViewActionType type);


@end

NS_ASSUME_NONNULL_END
